home *** CD-ROM | disk | FTP | other *** search
/ Creative Computers / Creative Computers CD-ROM, Volume 1 (Legendary Design Technologies, Inc.)(1994).iso / commercial / inovatronics / edgedemo / edgeeditor / rexx / menu_dosshell.edge < prev    next >
Text File  |  1994-11-17  |  1KB  |  39 lines

  1. /*
  2. ** $VER: OpenDOSShell.edge 1.2 (Sunday 08-Aug-93 02:49:57)
  3. **
  4. ** Script to open a shell console on the Edge screen. The current directory
  5. **    will be set to the current files path or if the path is zero to Edge's
  6. **    current directory. The window position/size/title is expected in 
  7. ** _GE_User0, and the shell startup file in _GE_User1. 
  8. ** 
  9. ** Written by Thomas liljetoft
  10. */
  11.  
  12.  
  13. options results
  14.  
  15. 'getenvvar' _ge_screenname        /* get name of the screen we're running on */
  16. screenname = result
  17.  
  18. 'getenvvar' _fe_path                /* get path of the current file */
  19. path = result
  20.  
  21. 'getenvvar' _ge_user0            /* get window position/size/title */
  22. window = result
  23. if length(window) = 0 then window = "20/20/600/50/AmigaShell/close"
  24.  
  25. 'getenvvar' _ge_user1            /* get shell startup file */
  26. startup = result
  27.  
  28. /* cd the current path */
  29. call pragma(d,path)
  30.  
  31. /* now open the shell console */
  32.  
  33. if length(startup) ~= 0 then
  34.     address command newshell '"'"con:"window"/SCREEN "screenname'"' from startup
  35. else
  36.     address command newshell '"'"con:"window"/SCREEN "screenname'"'
  37.  
  38. exit(RC)
  39.